package com.hanthink.web.controller.app.call;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.hanthink.common.core.domain.AjaxResult;
import com.hanthink.common.core.domain.entity.SysUser;

/**
 * <p>Title: ResourceCallController</p>
 * <p>Description: 资源呼叫</p>
 *
 * @author vondser
 * @date 2020年12月10日
 */
@RestController
@RequestMapping("/resource/call")
public class ResourceCallController {

    protected final Logger logger = LoggerFactory.getLogger(ResourceCallController.class);
    /**
     * 扫描查询呼叫信息
     */
    @GetMapping("/query")
    public AjaxResult queryResourceCallInfo(SysUser user) {
        // EM_CALL_RECORD资源呼叫记录表
        AjaxResult ajax = AjaxResult.success();
        return ajax;
    }

    /**
     * 保存呼叫信息
     */
    @PostMapping("/save")
    public AjaxResult saveEquipCheckInfo(SysUser user) {
        AjaxResult ajax = AjaxResult.success();
        //记录呼叫信息，记录消息通知

        //消息推送

//    	EM_CALL_RECORD资源呼叫记录表
//    	EM_RESOURCE_CALL 资源呼叫表
//    	EM_RESOURCE_CALL_GROUP 资源呼叫组表
//    	EM_NEWS_RECORD设备消息记录表

        return ajax;
    }

    /**
     * 更新呼叫信息
     */
    @PostMapping("/update")
    public AjaxResult updateEquipCheckInfo(SysUser user) {
        AjaxResult ajax = AjaxResult.success();
        //系统需更新当前项目结果为跳过

        return ajax;
    }

}
